package com.nbsaas.boot.marketing.rest.convert;

import com.nbsaas.boot.marketing.data.entity.PointsRule;
import com.nbsaas.boot.marketing.api.domain.simple.PointsRuleSimple;

import com.nbsaas.boot.rest.api.Converter;

/**
* 积分规则-列表对象转换器
*/

public class PointsRuleSimpleConvert implements Converter<PointsRuleSimple, PointsRule> {




@Override
public PointsRuleSimple convert(PointsRule source) {
    PointsRuleSimple result = new PointsRuleSimple();

                result.setMinAmount(source.getMinAmount());
                result.setCode(source.getCode());
                result.setMaxPoints(source.getMaxPoints());
                result.setName(source.getName());
                result.setAction(source.getAction());
                result.setDescription(source.getDescription());
                result.setId(source.getId());
                result.setType(source.getType());
                result.setAddDate(source.getAddDate());
                result.setPoints(source.getPoints());
                result.setStatus(source.getStatus());
                result.setLastDate(source.getLastDate());


    return result;
}

}